package chapter04;

import java.util.Scanner;

public class Day8 {
    public static void main(String[] args) {

        Scanner input = new Scanner(System.in);
        System.out.println("请输入薪资:");
        double salary = input.nextDouble();
        if (salary<=3500){
            System.out.println("无需交税");
        }
        else if(salary>3500 && salary<=8000){
            System.out.println("交税："+((salary-3500)*0.05));
        }
        else if(salary>8000 && salary<=15000){
            System.out.println("交税："+((salary-8000)*0.1+4500*0.05));
        }
        else{
            System.out.println("交税："+((salary-15000)*0.05+7000*0.1+4500*0.05));
        }

    }
    }

